package com.lmk.t02;

public class Bus extends MotoVehicle {
    private int setCont;

    public Bus(String no, String brand, int setCont) {
        super(no, brand);
        this.setCont = setCont;
    }

    public int getSetCont() {
        return setCont;
    }

    public void setSetCont(int setCont) {
        this.setCont = setCont;
    }

    @Override
    public int CalcRent(int days) {
        int rend=0;
        if (setCont<=16) {
            rend=800*days;
        }else if (setCont>16) {
            rend=1500*days;
        }
        return rend;
    }
    public void show(){
        System.out.println("车的型号是："+super.getBrand()+"车的座位是"+setCont);
    }
}
